package com.gill.controller;


import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

@Slf4j
@RestController
@RequestMapping("/provider")
public class ProviderController {

    @Value("${server.port}")
    private int port;

    @GetMapping(value = "/sayhello")
    public String providerSayHello(String message){

        log.error("provder sayhello port:{}, message:{}",port,message);

        return "service(Provider)\nmethod(sayhello)\nport("+port+" )\nmessage("+message+")";
    }
}
